home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 11832 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.1 KB

  1. Path: theory.lcs.mit.edu!wald
  2. From: wald@theory.lcs.mit.edu (David Wald)
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: A garbage collection problem in C++
  5. Date: 16 Mar 1996 14:43:05 GMT
  6. Organization: Theory of Computation, LCS, MIT
  7. Message-ID: <WALD.96Mar16094305@woodpecker.lcs.mit.edu>
  8. References: <4ic3vb$k0@mo6.rc.tudelft.nl> <4ic43s$k0@mo6.rc.tudelft.nl>
  9. NNTP-Posting-Host: woodpecker.lcs.mit.edu
  10. In-reply-to: Ejo Schrama's message of 15 Mar 1996 15:58:52 GMT
  11.  
  12. In article <4ic43s$k0@mo6.rc.tudelft.nl> Ejo Schrama
  13. <schrama@geo.tudelft.nl> writes:
  14. >the following code shows that the delete[] operator
  15. >will only treat the first argument as an array, the second argument
  16. >is not. It sounds like a easter-egg....
  17. ...
  18. >  delete[] a,b;
  19. ...
  20.  
  21. What do you mean "second argument"?  It looks like that statement should
  22. parse as "(delete[] a),b;", so the value of b is computed and discarded
  23. without ever being shown to delete[].
  24.  
  25. -David
  26. -- 
  27. ============================================================================
  28. David Wald      http://theory.lcs.mit.edu/~wald/     wald@theory.lcs.mit.edu
  29. ============================================================================
  30.